//
//  ViewController.m
//  UI22_复习Block
//
//  Created by Scott on 16/4/8.
//  Copyright © 2016年 Scott. All rights reserved.
//

#import "ViewController.h"
#import "TouchView.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
    
    [self createView];
}

- (void)createView {
    
    TouchView *view = [[TouchView alloc] initWithFrame:CGRectMake(20, 100, 300, 40) clickHandle:^(TouchView *view) {
    
        NSLog(@"ddd");
    }];
    
    view.backgroundColor = [UIColor redColor];
    
    [self.view addSubview:view];
}




- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
